package com.ssd.controller.consumer;


import com.baomidou.mybatisplus.core.incrementer.IdentifierGenerator;
import com.ssd.entity.Activity;
import com.ssd.entity.dto.response.SeizeCouponInfoResDTO;
import com.ssd.service.IActivityService;
import com.ssd.utils.IdUtils;
import com.ssd.view.BaseResponse;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

/**
 * <p>
 * 用户端-优惠券活动表 前端控制器
 * </p>
 *
 * @author author
 * @since 2024-11-21
 */
@RestController("consumerActivityController")
@RequestMapping("/consumer/activity")
@Api(tags = "用户端-优惠券活动表控制器")
public class ActivityController {

    @Resource
    private IActivityService activityService;


    /**
     * 用户端抢卷列表
     * @param tabType 活动类型
     * @return
     */
    @GetMapping("/list")
    @ApiOperation(value = "用户端抢卷列表查询")
    public List<SeizeCouponInfoResDTO> list(@RequestParam("tabType") Integer tabType){
        return activityService.queryForListForCache(tabType);
    }


}
